package server

import (
	"encoding/gob"
	"fmt"
	"github.com/astaxie/beego"
	"tinyrdm/server/models"
	"tinyrdm/server/routers"
	"tinyrdm/server/service"
)

func InitServer() {
	fmt.Printf("-------init---")
	gob.Register(models.User{})
	service.InitAdmin()
	routers.InitRoutes()
	fmt.Println("init success")
	beego.Run()
}
